# -*- coding: utf-8 -*-
"""
@Time : 2023/6/10 20:00
@Author : Gremore
@File : router
@Des: 
"""

from fastapi import APIRouter
from tsim.routers import user, plan # role, access, data
from collections import namedtuple
from tsim.routers.websocket import websocket
from tsim.routers.test import say_hello, test_redis_depends, test_redis, test_readdb

api_router = APIRouter(prefix="/api")
api_router.include_router(user.router, prefix='/user', tags=["用户管理"])
api_router.include_router(plan.router, prefix='/plan', tags=["计划管理"])

api_router.get("/test/hello", tags=["测试"])(say_hello)
api_router.post("/test/post", tags=["测试"])(say_hello)
# api_router.include_router(role.router, prefix='/admin', tags=["角色管理"])
# api_router.include_router(access.router, prefix='/admin', tags=["权限管理"])
api_router.include_router(websocket.router, prefix='/ws', tags=["WebSocket"])
# api_router.include_router(wechat.router, prefix='/wechat', tags=["微信授权"])
# api_router.include_router(sms.router, prefix='/sms', tags=["短信接口"])
# api_router.include_router(cos.router, prefix='/cos', tags=["对象存储接口"])


api_router.post("/test/redis/depends", tags=["测试"])(test_redis_depends)
api_router.post("/test/redis", tags=["测试"])(test_redis)
api_router.get("/test/mysql", tags=["测试"])(test_readdb)
